#ifndef SAMPLE_BOARD_H
#define SAMPLE_BAORD_H

#include "FmodEngine.h"
#include "IrrEngine.h"

class SampleBoard
{
public: 
	SampleBoard(int set, float x, float y);
	void Update(float master, bool mute);
	bool EventHandler(const SEvent& event);
	void SetVolume(int i);
	void Cleanup();
	void Override(float dist, float rev);

private:
	Channel* m_pChannel;
	Sound* m_pSample;
	int m_IdRangeStart;
	core::string<wchar_t> m_wFile;
	path m_Path;
	char* m_SampleName;
	bool m_bPaused;
	bool m_bLooping;
	bool m_bLPF;
	bool m_bHPF;
	bool m_bMute;
	bool m_bPlaying;
	bool m_bLastPlaying;
	IGUIButton* m_pPlayButton;
	IGUIScrollBar* m_pVolBar;
	IGUIScrollBar* m_pDistanceBar;
	IGUIScrollBar* m_pReverbBar;
	IGUIScrollBar* m_pPanBar;
	IGUIScrollBar* m_pPitchBar;
	IGUIScrollBar* m_pSpeedBar;
	IGUIStaticText* m_pFileDisplay;
	IGUIFileOpenDialog* m_pFileOpen;

	DSP* m_pDsp1;
	DSP* m_pDsp2;
	DSP* m_pPitchShifter;
	DSP* m_pReverb;
	f32 m_Vol;
	f32 m_Dist;
	f32 m_Pan;
	f32 m_Pitch;
	f32 m_Freq;
	f32 m_Speed;
	f32 m_Rev;
	FMOD_VECTOR m_vPos;

	f32 m_LastVol;
	f32 m_LastRev;
	f32 m_LastDist;
	f32 m_LastPan;
	f32 m_LastPitch;
	f32 m_LastSpeed;
};

#endif